{% load bootstrap %}
<div class="control-group{% if field.errors %} error{% endif %}">
    {% if field|is_checkbox %}
                <div class="controls">
                    <label class="checkbox">
                        {{ field }} <span>{{ field.label }}</span>
                    </label>

                    {% for error in field.errors %}
                        <span class="help-inline">{{ error }}</span>
                    {% endfor %}

                    {% if field.help_text %}
                    <p class="help-block">
                        {{ field.help_text }}
                    </p>
                    {% endif %}
                </div>
    {% else %}
        <div class="control-label">{{ field.label }}</div>

        <div class="controls">
            {{ field }}

            {% for error in field.errors %}
                <span class="help-inline">{{ error }}</span>
            {% endfor %}

            {% if field.help_text %}
            <p class="help-block">
                {{ field.help_text }}
            </p>
            {% endif %}

        </div>
    {% endif %}
</div>
